﻿define(['ko','utils','config'], function(ko, utils, config) {
		this.text = ko.observable();
		var loadData = function(){
			this.text('test link2');
		};
		var activate = function(){
			loadTemplate.call(this);
		};
		var loadTemplate =  function(){
			var self = this;
			utils.loadTemplate(config.viewIds.link2,"default/tmpl/" + config.viewTplNames.link2,function(){
				bind.call(self);
			});
			loadData();
		};
		var bind = function(){
			ko.applyBindings(this, $(config.viewIds.link2).get(0));
		};
	return {
		activate: activate
	};
}); 